import { createRouter, createWebHistory } from 'vue-router'
import Home from '../views/Home.vue'
import Diary from '../views/Diary.vue'
import My from '../views/My.vue'
import Guide from "@/views/guide";
import Food from "@/views/food/Food";
import FoodDetail from "@/views/food/FoodDetail";
import View from "@/views/view/View";
import ViewDetail from "@/views/view/ViewDetail";
import TicketList from "@/views/ticket/TicketList";
import TicketDetail from "@/views/ticket/TicketDetail";
import TicketChat from "@/views/ticket/TicketChat";
import TicketCart from "@/views/ticket/TicketCart";
import TicketOrderPrefix from "@/views/ticket/TicketOrderPrefix";
import PhoneRegister from "@/views/user/phoneRegister";
import PhoneLogin from "@/views/user/phoneLogin";
import FindPass from "@/views/user/findPass";
import GoodsList from "@/views/Goods/GoodsList";
const routes = [
  {
    path: '/',
    name: 'home',
    component: Home,
    meta: {
      TabbarShow: true  // 需要显示 底部导航
    }
  },
  {
    path: '/viewDetail',
    name: 'viewDetail',
    component: ViewDetail
  },
  {
    path: '/view',
    name: 'view',
    component: View
  },
  {
    path: '/my',
    name: 'my',
    component: My,
    meta: {
      TabbarShow: true  // 需要显示 底部导航
    }
  },

  {
    path: '/diary',
    name: 'diary',
    component: Diary,
    meta: {
      TabbarShow: true  // 需要显示 底部导航
    }
  },
  {
    path: '/guide',
    name: 'guide',
    component: Guide
  },
  {
    path: '/food',
    name: 'food',
    component: Food,

  },
  {
    path: '/foodsdetail',
    name: 'foodsdetail',
    component: FoodDetail,

  }, {
    path: '/ticket',
    name: 'ticket',
    component: TicketList
  },
  {
    path: '/ticketchat',
    name: 'ticketchat',
    component: TicketChat
  },
  {
    path: '/ticketdetail',
    name: 'ticketdetail',
    component: TicketDetail
  },
  {
    path: '/ticketcart',
    name: 'ticketcart',
    component: TicketCart
  },
  {
    path: '/ticketorderprefix',
    name: 'ticketorderprefix',
    component: TicketOrderPrefix
  },
  {
    path: '/phoneLogin',
    name: 'phoneLogin',
    component: PhoneLogin
  },
  {
    path: '/phoneRegister',
    name: 'phoneRegister',
    component: PhoneRegister
  },
  {
    path: '/findPass',
    name: 'findPass',
    component: FindPass
  },
  {
    path: '/goodsList',
    name: 'goodsList',
    component: GoodsList
  }

]

const router = createRouter({
  history: createWebHistory(process.env.BASE_URL),
  routes
})

export default router
